<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
       xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:p="http://primefaces.prime.com.tr/ui">
    <h:head>
        
    </h:head>
    <f:view>
               <h:form id="UserForm" prependId="false" >
                   <p:growl id="growl" showDetail="true" life="3000" /> 
                         <p:panel header=" Học Phần" style="background-color: #ebf3fd;">  
                            <h:panelGrid columns="2" cellpadding="5">  
                                         <h:outputLabel  value=" Mã Lớp : *" />  
                                         <h:outputLabel value="#{lopController.getRequestParam()}"   id="username" />  
                                         <h:outputLabel for="tenmh" value="Tên Lớp : * " />  
                                         <p:inputText value="#{lopController.lop.tenhp}"   id="tenmh" required="true" label="Tên Môn Học" />  
                                          <h:outputLabel  value=" Giáo Viên:  " />  
                                         <h:selectOneMenu id = "managerListBox" value ="#{lopController.lop.magv}"  onchange="submit()"   >
                                             <f:selectItems value = "#{lopController.getAllGiaoVien()}" itemLabel ="#{lopController.getAllGiaoVien()}"  />
                                         </h:selectOneMenu>
                                           <h:outputLabel  value=" Môn Học :  " />  
                                         <h:selectOneMenu id = "listMonHoc" value ="#{lopController.lop.mamh}"  >
                                              <f:valueChangeListener type="controller.LopController" />
                                             <f:selectItems value = "#{lopController.getAllMonHoc()}"  />
                                         </h:selectOneMenu>
                                           <h:outputLabel  value=" Học Kỳ :  " />  
                                         <h:selectOneMenu id = "listHocKy" value ="#{lopController.lop.mahk}"   >
                                             <f:selectItems value = "#{lopController.getAllHocKy()}" itemDescription="#{lopController.getAllHocKy()}"  />
                                         </h:selectOneMenu> 
   
                                           <h:commandButton value="Xong "   action="#{lopController.backPage(lopController.lop)}"   > 
                                                <f:param name="id_giaovien" value="#{lopController.id_giaovien}" />
                                                
                                           </h:commandButton>              
                                      
                           </h:panelGrid> 
                       </p:panel> 
               </h:form>
    </f:view>
</html>

